<template>
	<view>
		<mumu-one-code @success='handlerSuccess' definition :readers='["ean_reader"]'></mumu-one-code>
	</view>
</template>

<script>
	import MumuOneCode from '@/uni_modules/mumu-oneCode/components/mumu-oneCode/mumu-oneCode.vue'
	export default {
		components: {
			MumuOneCode
		},
		data() {
			return {
				readers:["code_128_reader","ean_reader","ean_8_reader","code_39_reader","code_39_vin_reader","codabar_reader","upc_reader","upc_e_reader","i2of5_reader","2of5_reader","code_93_reade"]
			}
		},
		methods: {
			handlerSuccess(code) {
				uni.redirectTo({
					url: "/pages_index/search?name=" + code
				})
				// uni.showModal({
				// 	content: code
				// }).then(res => {
				// 	uni.navigateBack()
				// })
			}
			
		}
	}
</script>

<style>

</style>